import React from 'react'
import {Input, Modal} from 'antd'
import {FormattedMessage} from 'react-intl'

const {TextArea} = Input

const QuizNoteModal = ({isQuizNoteModalVisible, handleOk, handleCancel, handelChangeNote}) => {
    const handAttribute = (e) => {
        handelChangeNote(e.target.value)
    }
    return <Modal
        title={<FormattedMessage id='学员题目备忘录'/>}
        visible={isQuizNoteModalVisible}
        onOk={handleOk}
        onCancel={handleCancel}
        cancelText={<FormattedMessage id='取消'/>}
        okText={<FormattedMessage id='确定'/>}
        destroyOnClose>
        <TextArea rows={3} onChange={handAttribute.bind(this)}/>
    </Modal>
}

export default QuizNoteModal
